package com.example.demo.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("permission")
public class Permission {
    @TableId(value = "permission_id",type = IdType.AUTO)
    @ApiModelProperty(value = "权限ID")
    private Integer permissionId;
    @ApiModelProperty(value = "权限名称",required = true)
    private String permissionName;
    @ApiModelProperty(value = "权限等级",required = true)
    private String permissionLabel;
    @TableField(exist = false)
    private List<Permission> children;
    private Integer pid;
}
